<% add_decidim_page_title(component_name) %>
<%= append_javascript_pack_tag "decidim_initiatives" %>
<%= append_stylesheet_pack_tag "decidim_initiatives", media: "all" %>

<%
edit_link(
  decidim_admin_initiatives.initiatives_path,
  :read,
  :initiative
)
%>

<% content_for :aside do %>
  <h1 class="title-decorator"><%= component_name %></h1>
  <%= render partial: "new_initiative_button" %>

  <%= render layout: "decidim/shared/filters", locals: { filter_sections: , search_variable: :search_text_cont, skip_to_id: "initiatives" } do %>
    <%= hidden_field_tag :order, order, id: nil, class: "order_filter" %>
  <% end %>
<% end %>

<%= render layout: "layouts/decidim/shared/layout_two_col" do %>
  <%= participatory_space_floating_help %>

  <% if pending_initiatives.any? %>
    <div class="pending-initiatives">
      <section id="pending_initiatives" class="layout-main__section layout-main__heading">
        <%= render partial: "pending_initiatives" %>
      </section>
    </div>
  <% end %>

  <section id="initiatives" class="layout-main__section layout-main__heading">
    <%= render partial: "initiatives" %>
  </section>
<% end %>
